﻿using System;

namespace YWM.Common.Exceptions
{
    public class FriendlyException : Exception
    {
        /// <summary>
        /// 构造函数
        /// </summary>
        public FriendlyException() : base()
        {
        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="message"></param>
        public FriendlyException(string message) : base(message)
        {
        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="message"></param>
        /// <param name="errorCode"></param>
        public FriendlyException(string message, Exception originException) : base(message)
        {
            OriginException = originException;
        }

        /// <summary>
        /// 原始异常
        /// </summary>
        public Exception OriginException { get; set; }
    }
}
